package com.xiaogao.serviceBase.utils.exceptionHandler;

import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * @author 小高
 * @createtime 2021-05-30-23:18
 * @description 自定义异常类
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class XiaoGaoException extends RuntimeException {

    @ApiModelProperty(value = "状态码")
    private Integer code;

    @ApiModelProperty(value = "异常信息")
    private String msg;

//    @Override
//    public String toString() {
//        return "XiaoGaoException{" +
//                "message=" + this.getMessage() +
//                ", code=" + code +
//                '}';
//    }
}
